home *** CD-ROM | disk | FTP | other *** search
- int target_flags;
-
- main() {
- set_target_switch("");
- }
-
- struct {char *name; int value;} target_switches []
- = { { "68020", 5},
- { "c68020", 5},
- { "68881", 2},
- { "c68881", 2},
- { "bitfield", 4},
- { "68000", -5},
- { "c68000", -5},
- { "soft-float", -0102},
- { "nobitfield", -4},
- { "rtd", 8},
- { "nortd", -8},
- {"short", 040},
- { "noshort", -040},
- { "fpa", 0100},
- { "nofpa", -0100},
- { "sky", 0200},
- { "nosky", -0200},
- { "68040", 0407},
- { "68030", -01400},
- { "68030", 7},
- { "68040-only", 01000},
- { "bgfull", 0x2000 },
- { "bgoff", -0x2000 },
- { "elems881", 0x4000},
- { "m", 0x8000},
- { "sane", 0x10000 },
- { "insane", -0x10000 },
- { "nointlib", -0x20000 },
- { "b", 0x40000 },
- { "fx30", 0x80000 },
- { "noseg", 0x100000 },
- { "", 0x32000 }} ;
-
- int
- set_target_switch (name)
- char *name;
- {
- register int j;
- int valid = 0;
-
- for (j = 0; j < 32; j++)
- if (!strcmp (target_switches[j].name, name))
- {
- if (target_switches[j].value < 0)
- target_flags &= ~-target_switches[j].value;
- else
- target_flags |= target_switches[j].value;
- valid = 1;
- }
-
-
- if (!valid)
- printf ("Invalid option7 `%s'", name);
- }
-
-